import request from '@/utils/request'

const prefix = "/api/index"

/** 
 * 首页数据
 */
function data() {
	return request({
		url: prefix + '/data',
		method: 'get'
	})
}

// 我的错题/收藏集
function mineErrorCollectSet(type) {
	return request({
		url: prefix + '/mineErrorCollectSet/' + type,
		method: 'get'
	})
}

function Search(keyword) {
	return request({
		url: prefix + '/search?keyword=' + keyword,
		method: 'get'
	})
}


/** 
 * 科目数据
 */
function SubjectList() {
	return request({
		url: prefix + '/subjectList',
		method: 'get'
	})
}



export default {
	data,
	mineErrorCollectSet,
	Search,
	SubjectList
}